package cn.juque.workflow.api.dto.leaveinfo;

import cn.juque.common.abstracts.AbstractRequestDTO;
import lombok.Data;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.Date;

/**
 * @author JUQUE
 * @version 1.0.0
 * <ul>
 *  <li>simple-generator</li>
 *  <li>请假申请单信息</li>
 * </ul>
 * @date 2023-01-31 18:14:44
 **/
@Data
public class LeaveInfoUpdateDTO extends AbstractRequestDTO {

    /**
     * 主键
     */
    @NotEmpty(message = "主键不能为空")
    @Size(message = "主键不能超过{max}个字符", max = 32)
    private String id;

    /**
     * 标题
     */
    @NotEmpty(message = "标题不能为空")
    @Size(message = "标题不能超过{max}个字符", max = 100)
    private String title;

    /**
     * 开始时间
     */
    @NotNull(message = "开始时间不能为空")
    private Date startTime;

    /**
     * 结束时间
     */
    @NotNull(message = "结束时间不能为空")
    private Date endTime;

    /**
     * 请假原因
     */
    @Size(message = "请假原因不能超过{max}个字符", max = 100)
    private String reason;
}
